package com.lp.model.entity.article.redis;

import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 
 * @TableName likesMsg
 */
@Data
public class LikesMsg implements Serializable {

    /**
     * 哪个用户的消息
     */
    private Long userId;

    /**
     * 谁点的赞
     */
    private Long fromId;

    /**
     * 给那篇文章点赞
     */
    private Long postId;

    /**
     * 创建时间: 默认精确到秒
     */
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    public LikesMsg(Long userId, Long fromId, Long postId, Date createTime) {
        this.userId = userId;
        this.fromId = fromId;
        this.postId = postId;
        this.createTime = createTime;
    }

    public LikesMsg() {

    }

    private static final long serialVersionUID = 1L;

}